﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Rem.Objects
{
    public class QueryConstants
    {
        public const int UnsavedObjectId = -1;
        public const int DefaultAdvanceDays = 7;

        //拷贝 basetype, id, name
        public const string CloneFomateTitleTemplate = "拷贝:" + FomateTileTemplate;
        // basetype, id, name
        public const string FomateTileTemplate = "{0}{1}{2}";

        public const string IDTemplate = "编号:{0}";

        public const int AdvanceReminderDays = 7;
        public const string MaxId = "MaxId";

        public static Dictionary<string, string> ReminderFieldNameHeadTextMapping
        {
            get
            {
                Dictionary<string, string> result = new Dictionary<string, string>();
                result.Add("Id", "编号");
                //result.Add("ReminderTime", "提醒时间");
                result.Add("ReminderTimeString", "提醒时间");
                result.Add("Category", "分类");
                result.Add("Message", "提醒信息");
                result.Add("Status", "状态");
                //result.Add("StartTime", "开始时间");
                //result.Add("DueTime", "结束时间");
                //result.Add("ReminderCategoryId", "分类编号");
                //result.Add("ReminderMessageTemplateId", "信息模板编号");
                //result.Add("ReminderMessageTemplate", "信息模板");
                //result.Add("ReminderSound", "响铃声音");
                //result.Add("ReminderCategoryName","分类");
                // result.Add("ContractId", "合同编号");
                return result;

            }
        }

        public static List<string> ReminderInvisiableFieldNames
        {
            get
            {
                List<string> result = new List<string>();
                //result.Add("Id");
                result.Add("ContractId");
                result.Add("Contract");
                result.Add("AdvancedDays");
                result.Add("ReminderTime");
                //result.Add("Status");
                //result.Add("ReminderCategory");
                result.Add("CreatedTime");//, "提醒生成时间");
                result.Add("ReminderMessageTemplate");
                result.Add("RelatedRent");
                result.Add("ReminderSound");
                result.Add("ReminderCategoryName");
                result.Add("StartTime");
                result.Add("DueTime");
                result.Add("BatchId");
                result.Add("FileName");
                result.Add("SquNum");
                return result;
            }
        }

        public static Dictionary<string, string> EmployeeFieldNameHeadTextMapping
        {
            get
            {
                Dictionary<string, string> result = new Dictionary<string, string>();
                result.Add("Id", "编号");
                result.Add("Name", "姓名");
                result.Add("Title", "头衔");
                result.Add("Birthday", "生日");
                result.Add("BasicSalary", "基本薪水");
                result.Add("Phones", "电话");
                result.Add("Memo", "备注");
                return result;
            }
        }
        public static List<string> EmployeeInvisiableFieldNames
        {
            get
            {
                List<string> result = new List<string>();
                // result.Add("Id");
                result.Add("Contracts");
                return result;
            }
        }

        public static Dictionary<string, string> CustomerFieldNameHeadTextMapping
        {
            get
            {
                Dictionary<string, string> result = new Dictionary<string, string>();
                result.Add("Id", "编号");
                result.Add("Name", "客户名称");
                result.Add("CardId", "身份证");
                result.Add("Phone", "电话");
                result.Add("Comment", "备注");
                return result;

            }
        }

        public static List<string> CustomerInvisiableFieldNames
        {
            get
            {
                List<string> result = new List<string>();
                result.Add("Contracts");
                result.Add("Contracts1");
                result.Add("FileName");
                return result;
            }
        }

        public static Dictionary<string, string> ContractFieldNameHeadTextMapping
        {
            get
            {
                Dictionary<string, string> result = new Dictionary<string, string>();
                result.Add("Id", "编号");
                result.Add("Address", "商铺地址");
                result.Add("SignTime", "签约时间");
                result.Add("CustomerPartA.Name", "收租方");
                result.Add("CustomerPartB.Name", "缴租方");
                result.Add("TotalRent", "总租金");
                result.Add("RentInterval", "收缴租周期");
                //result.Add("RentPerInterval", "每月租金");
                result.Add("RentInfo", "租金信息");
                result.Add("Deposit", "押金");

                result.Add("ContractNo", "合同编号");
                result.Add("Width", "门面宽");
                result.Add("AreaSize", "面积");
                result.Add("AdvancedDays", "提前交租天数");
                result.Add("StartDateString", "开始日期");
                result.Add("DueDateString", "结束日期");
                result.Add("FreeDaysIn", "合同内免租期(天)");
                result.Add("FreeDaysOut", "合同外免租期(天)");
                result.Add("Comment", "备注");
                result.Add("CanTicket", "是否开票");
                result.Add("AdvancedRenew", "提前续约天数");
                return result;
            }
        }

        public static List<string> ContractInvisiableFieldNames
        {
            get
            {
                List<string> result = new List<string>();
                result.Add("RentPerInterval");
                result.Add("RentUnit");
                result.Add("SignTime");
                result.Add("CustomerId");
                result.Add("EmployeeId");
                result.Add("Employee");
                result.Add("Customer");
                result.Add("Reminders");

                result.Add("TaxRate");
                result.Add("RentInInterval");
                result.Add("RentInYear");

                result.Add("SubmitRentDate");//, "交租日期");
                result.Add("StartDate");
                result.Add("DueDate");
                result.Add("ContractAddtionalInfoes");
                result.Add("CustomerPartA");
                result.Add("CustomerPartB");
                result.Add("PartAId");
                result.Add("PartBId");
                result.Add("Width");
                result.Add("AreaSize");
                result.Add("Comment");
                result.Add("FreeDaysIn");
                result.Add("FreeDaysOut");
                result.Add("CustomerPartA.Name");
                result.Add("CustomerPartB.Name");
                result.Add("Status");
                result.Add("FileName");
                return result;
            }
        }


        public static Dictionary<string, string> ContractAdditionalInfoFieldNameHeadTextMapping
        {
            get
            {
                Dictionary<string, string> result = new Dictionary<string, string>();
                result.Add("Id", "编号");
                result.Add("Key", "项目名称");
                result.Add("Value", "项目内容");
                return result;
            }
        }

        public static List<string> ContractAdditionalInfoInvisiableFieldNames
        {
            get
            {
                List<string> result = new List<string>();
                result.Add("Contract");
                result.Add("ContractId");
                return result;
            }
        }
    }
}
